package com.ssy.lingxi.platform.manage.repository;

import com.ssy.lingxi.platform.manage.entity.base.Area;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface AreaRepository extends JpaRepository<Area, Long> {

    List<Area> findAllByPcodeIn(List<String> pcodes);

    List<Area> findAllByPcodeEquals(String pcode);

    List<Area> findAllByPcode(String pcode);

    List<Area> findAllByLevel(Integer level);

    Area findOneByCode(String code);
}
